package cn.iocoder.yudao.module.system.dal.dataobject.merchant;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;

import lombok.Data;

/**
 * 
 * @TableName system_merchant_auth
 */
@TableName(value ="system_merchant_auth")
@Data
public class SystemMerchantAuth implements Serializable {

    @TableId
    private Integer id;

    /**
     * 农产品商家id
     */
    private Long userId;

    /**
     * 审核人
     */
    private Long handler;

    /**
     * 商家名称
     */
    private String merchantName;

    /**
     * 商家logo
     */
    private String logo;

    /**
     * 法定代表人
     */
    private String legalRepresentative;

    /**
     * 身份证照片
     */
    private String identifyCard;

    /**
     * 营业执照编号
     */
    private String businessLicense;


    /**
     * 商家身份
     */
    private Integer identify;

    /**
     * 联系电话
     */
    private String contactPhone;

    /**
     * 认证状态
     */
    private Integer certificationStatus;

    /**
     * 认证日期
     */
    private LocalDateTime certificationDate;

    /**
     * 认证时的备注
     */
    private String remarks;

    /**
     * 记录创建日期
     */
    private LocalDateTime createTime;

    /**
     * 记录最近更新时间
     */
    private LocalDateTime updateTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        SystemMerchantAuth other = (SystemMerchantAuth) that;
        return (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
            && (this.getMerchantName() == null ? other.getMerchantName() == null : this.getMerchantName().equals(other.getMerchantName()))
            && (this.getLegalRepresentative() == null ? other.getLegalRepresentative() == null : this.getLegalRepresentative().equals(other.getLegalRepresentative()))
            && (this.getBusinessLicense() == null ? other.getBusinessLicense() == null : this.getBusinessLicense().equals(other.getBusinessLicense()))
            && (this.getIdentify() == null ? other.getIdentify() == null : this.getIdentify().equals(other.getIdentify()))
            && (this.getCertificationStatus() == null ? other.getCertificationStatus() == null : this.getCertificationStatus().equals(other.getCertificationStatus()))
            && (this.getCertificationDate() == null ? other.getCertificationDate() == null : this.getCertificationDate().equals(other.getCertificationDate()))
            && (this.getRemarks() == null ? other.getRemarks() == null : this.getRemarks().equals(other.getRemarks()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getUserId() == null) ? 0 : getUserId().hashCode());
        result = prime * result + ((getMerchantName() == null) ? 0 : getMerchantName().hashCode());
        result = prime * result + ((getLegalRepresentative() == null) ? 0 : getLegalRepresentative().hashCode());
        result = prime * result + ((getBusinessLicense() == null) ? 0 : getBusinessLicense().hashCode());
        result = prime * result + ((getIdentify() == null) ? 0 : getIdentify().hashCode());
        result = prime * result + ((getCertificationStatus() == null) ? 0 : getCertificationStatus().hashCode());
        result = prime * result + ((getCertificationDate() == null) ? 0 : getCertificationDate().hashCode());
        result = prime * result + ((getRemarks() == null) ? 0 : getRemarks().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(userId);
        sb.append(", merchant_name=").append(merchantName);
        sb.append(", legal_representative=").append(legalRepresentative);
        sb.append(", business_license=").append(businessLicense);
        sb.append(", identify=").append(identify);
        sb.append(", certification_status=").append(certificationStatus);
        sb.append(", certification_date=").append(certificationDate);
        sb.append(", remarks=").append(remarks);
        sb.append(", create_time=").append(createTime);
        sb.append(", update_time=").append(updateTime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}